<template>
	<div>
		<h2>Category</h2>
	</div>
</template>

<script>
import eventBus from '../utils/event-bus'
export default {
	methods: {
		whyEventHandler() {
			console.log('Category name, age, height: ', name, age, height)
		},
	},
	created() {
		eventBus.on('whyEvent', this.whyEventHandler)
	},
	unmounted() {
		console.log('Category移除')
		eventBus.off('whyEvent', this.whyEventHandler)
	},
}
</script>

<style scoped></style>
